// @ts-ignore
/* eslint-disable */
import request from '@/request'

/** 此处后端没有提供注释 GET /server/info/${param0} */
export async function getServerInfo(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getServerInfoParams,
  options?: { [key: string]: any }
) {
  const { serverId: param0, ...queryParams } = params
  return request<Record<string, any>>(`/server/info/${param0}`, {
    method: 'GET',
    params: { ...queryParams },
    ...(options || {})
  })
}

/** 此处后端没有提供注释 GET /server/list */
export async function getServerList(options?: { [key: string]: any }) {
  return request<Record<string, any>[]>('/server/list', {
    method: 'GET',
    ...(options || {})
  })
}

/** 此处后端没有提供注释 POST /server/ping/${param0} */
export async function pingServer(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.pingServerParams,
  options?: { [key: string]: any }
) {
  const { serverId: param0, ...queryParams } = params
  return request<Record<string, any>>(`/server/ping/${param0}`, {
    method: 'POST',
    params: { ...queryParams },
    ...(options || {})
  })
}

/** 此处后端没有提供注释 POST /server/refresh */
export async function refreshServerList(options?: { [key: string]: any }) {
  return request<Record<string, any>>('/server/refresh', {
    method: 'POST',
    ...(options || {})
  })
}

/** 此处后端没有提供注释 GET /server/statistics */
export async function getServerStatistics(options?: { [key: string]: any }) {
  return request<Record<string, any>>('/server/statistics', {
    method: 'GET',
    ...(options || {})
  })
}

/** 此处后端没有提供注释 GET /server/status */
export async function getCurrentServerStatus(options?: { [key: string]: any }) {
  return request<Record<string, any>>('/server/status', {
    method: 'GET',
    ...(options || {})
  })
}
